package com.tjs.lucky.infrastructure.mapper;

import com.tjs.lucky.infrastructure.po.RuleTreeNodeLine;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Author: 田佳澍
 * @Description:
 * @DateTime: 2023/5/29 14:40
 **/
@Mapper
public interface RuleTreeNodeLineMapper {
    /**
     * 根据给定的规则树Id,查询某一个节点下的【所有节点连线】。
     *
     * @param treeId     规则树Id
     * @param nodeIdFrom 树节点
     * @return 节点连线集合
     */
    List<RuleTreeNodeLine> queryRuleTreeNodeLineList(@Param("treeId") Long treeId, @Param("nodeIdFrom") Long nodeIdFrom);

    /**
     * 查询规则树连线数量
     *
     * @param treeId 规则树ID
     * @return 规则树连线数量
     */
    int queryTreeNodeLineCount(Long treeId);

}
